<?php

use Carbon\Carbon;
use Illuminate\Database\Seeder;

class MenusTableSeeder extends Seeder
{
    /**
     * Run the database seeds.
     *
     * @return void
     */
    public function run()
    {
    	$menus = [
			[
				'id' => 1,
				'parent_id' => 0,
				'name' => '首页',
				'icon' => 'icon-shouyeshouye',
				'path' => 'dashboard',
				'component' => 'Dashboard',
				'meta' => json_encode([
					'title' => '首页',
					'requiresAuth' => true
				]),
				'created_at' => Carbon::now(),
				'updated_at' => Carbon::now()
			], [
    			'id' => 2,
    			'parent_id' => 0,
    			'name' => '基础档案',
    			'icon' => 'icon-jichushuju',
    			'path' => null,
    			'component' => null,
    			'meta' => null,
				'created_at' => Carbon::now(),
				'updated_at' => Carbon::now()
			],[
    			'id' => 3,
    			'parent_id' => 0,
    			'name' => '审核管理',
    			'icon' => 'icon-msnui-task',
    			'path' => null,
    			'component' => null,
    			'meta' => null,
				'created_at' => Carbon::now(),
				'updated_at' => Carbon::now()
			],[
    			'id' => 4,
    			'parent_id' => 0,
    			'name' => '分析报表',
    			'icon' => 'icon-weibiaoti1',
    			'path' => null,
    			'component' => null,
    			'meta' => null,
				'created_at' => Carbon::now(),
				'updated_at' => Carbon::now()
			],[
    			'id' => 5,
    			'parent_id' => 0,
    			'name' => '通知信息',
    			'icon' => 'icon-tongzhi',
    			'path' => null,
    			'component' => null,
    			'meta' => null,
				'created_at' => Carbon::now(),
				'updated_at' => Carbon::now()
			],[
    			'id' => 6,
    			'parent_id' => 0,
    			'name' => '系统管理',
    			'icon' => 'icon-xitong2',
    			'path' => null,
    			'component' => null,
    			'meta' => null,
				'created_at' => Carbon::now(),
				'updated_at' => Carbon::now()
			],[
    			'id' => 7,
    			'parent_id' => 2,
    			'name' => '公司管理',
    			'icon' => 'icon-gongsi',
    			'path' => 'company',
    			'component' => 'Company',
    			'meta' => json_encode([
					'title' => '公司管理',
					'requiresAuth' => true
				]),
				'created_at' => Carbon::now(),
				'updated_at' => Carbon::now()
			],[
    			'id' => 8,
    			'parent_id' => 2,
    			'name' => '组织管理',
    			'icon' => 'icon-mendianguanli',
    			'path' => 'shop',
    			'component' => 'Shop',
				'meta' => json_encode([
					'title' => '组织管理',
					'requiresAuth' => true
				]),
				'created_at' => Carbon::now(),
				'updated_at' => Carbon::now()
			],[
				'id' => 9,
				'parent_id' => 2,
				'name' => '人员管理',
				'icon' => 'icon-caifang-renyuan',
				'path' => 'user',
				'component' => 'User',
				'meta' => json_encode([
					'title' => '人员管理',
					'requiresAuth' => true
				]),
				'created_at' => Carbon::now(),
				'updated_at' => Carbon::now()
			],[
                'id' => 10,
                'parent_id' => 2,
                'name' => '任务管理',
                'icon' => 'icon-msnui-task',
                'path' => 'task',
                'component' => 'Task',
                'meta' => json_encode([
                    'title' => '任务管理',
                    'requiresAuth' => true
                ]),
                'created_at' => Carbon::now(),
                'updated_at' => Carbon::now()
            ],[
    			'id' => 11,
    			'parent_id' => 2,
    			'name' => '任务绑定',
    			'icon' => 'icon-hesuankemuleixing',
    			'path' => 'category',
    			'component' => 'Category',
				'meta' => json_encode([
					'title' => '任务绑定',
					'requiresAuth' => true
				]),
				'created_at' => Carbon::now(),
				'updated_at' => Carbon::now()
			],[
    			'id' => 12,
    			'parent_id' => 4,
    			'name' => '组织维度报表',
    			'icon' => 'icon-mendian',
    			'path' => 'shop-report',
    			'component' => 'ShopReport',
				'meta' => json_encode([
					'title' => '组织维度报表',
					'requiresAuth' => true
				]),
				'created_at' => Carbon::now(),
				'updated_at' => Carbon::now()
			],[
    			'id' => 13,
    			'parent_id' => 4,
    			'name' => '人员维度报表',
    			'icon' => 'icon-renyuanjiankong',
    			'path' => 'user-report',
    			'component' => 'UserReport',
				'meta' => json_encode([
					'title' => '人员维度报表',
					'requiresAuth' => true
				]),
				'created_at' => Carbon::now(),
				'updated_at' => Carbon::now()
			],[
    			'id' => 14,
    			'parent_id' => 4,
    			'name' => '计划维度报表',
    			'icon' => 'icon-renwuchaxun',
    			'path' => 'task-report',
    			'component' => 'TaskReport',
				'meta' => json_encode([
					'title' => '计划维度报表',
					'requiresAuth' => true
				]),
				'created_at' => Carbon::now(),
				'updated_at' => Carbon::now()
			],
			[
    			'id' => 16,
    			'parent_id' => 3,
    			'name' => '任务审核',
    			'icon' => 'icon-msnui-task',
    			'path' => 'audit-task',
    			'component' => 'AuditTask',
				'meta' => json_encode([
					'title' => '任务审核',
					'requiresAuth' => true
				]),
				'created_at' => Carbon::now(),
				'updated_at' => Carbon::now()
			],[
    			'id' => 17,
    			'parent_id' => 3,
    			'name' => '计划审核',
    			'icon' => 'icon-jihua',
    			'path' => 'audit-plan',
    			'component' => 'AuditPlan',
				'meta' => json_encode([
					'title' => '计划审核',
					'requiresAuth' => true
				]),
				'created_at' => Carbon::now(),
				'updated_at' => Carbon::now()
			],[
    			'id' => 18,
    			'parent_id' => 3,
    			'name' => '请假审核',
    			'icon' => 'icon-qingjiadandaoru',
    			'path' => 'audit-leave',
    			'component' => 'ReportLeave',
				'meta' => json_encode([
					'title' => '请假审核',
					'requiresAuth' => true
				]),
				'created_at' => Carbon::now(),
				'updated_at' => Carbon::now()
			],[
    			'id' => 19,
    			'parent_id' => 5,
    			'name' => '发布通知',
    			'icon' => 'icon-fabu',
    			'path' => 'notification',
    			'component' => 'Notification',
				'meta' => json_encode([
					'title' => '发布通知',
					'requiresAuth' => true
				]),
				'created_at' => Carbon::now(),
				'updated_at' => Carbon::now()
			],[
    			'id' => 20,
    			'parent_id' => 6,
    			'name' => '角色管理',
    			'icon' => 'icon-yidongyunkongzhitaiicon45',
    			'path' => 'role',
    			'component' => 'SystemRole',
				'meta' => json_encode([
					'title' => '发布通知',
					'requiresAuth' => true
				]),
				'created_at' => Carbon::now(),
				'updated_at' => Carbon::now()
			],[
    			'id' => 21,
    			'parent_id' => 6,
    			'name' => 'Banner管理',
    			'icon' => 'icon-lunboxiaoguo',
    			'path' => 'banner',
    			'component' => 'SystemBanner',
				'meta' => json_encode([
					'title' => 'Banner管理',
					'requiresAuth' => true
				]),
				'created_at' => Carbon::now(),
				'updated_at' => Carbon::now()
			],[
                'id' => 22,
                'parent_id' => 4,
                'name' => '组织数据报表',
                'icon' => 'icon-lunboxiaoguo',
                'path' => 'xun-dian-shu-ju',
                'component' => 'XunDianShuJu',
                'meta' => json_encode([
                    'title' => '巡店数据报表',
                    'requiresAuth' => true
                ]),
                'created_at' => Carbon::now(),
                'updated_at' => Carbon::now()
            ]
		];

    	DB::table('menus')->insert($menus);
    }
}
